package com.lc.projects.unit.socket.rmi;

import java.net.MalformedURLException;
import java.rmi.Naming;
import java.rmi.NotBoundException;
import java.rmi.RemoteException;

public class Client {
	public static void main(String[] args) {
		try {
			SumInterface clientSum = (SumInterface) Naming.lookup("rmi://127.0.0.1:8088/server");
			System.out.println(clientSum.getSum(1, 2));
		} catch (MalformedURLException | RemoteException | NotBoundException e) {
			e.printStackTrace();
		}
	}
}
